
# -*- coding: utf-8 -*-

'''
/*PHP是世界上最好的语言/*
'''

from base_config import *
from manage.exception import Exceptions
import requests,os,time

def checkPdd(url=domain_url['other']['pdd_tag_url']):

    anti = 'labelTextV2'

    # try:

    r = requests.get( url+'4578895175' ,headers=header )

    ip = lambda : requests.get( url = 'http://ip.42.pl/raw').text

    print('当前ip:',ip())

    if r.status_code == 200 and anti not in r.text:

        os.system('python D:\\拼多多站外工具箱\\requestTask.py')


        # Exceptions.resetConnet()

    else:


        Exceptions.resetConnet()

        checkPdd()

        # Exceptions.resetConnet()
        #
        # while True:
        #
        #     code = lambda : requests.get(url='https://www.baidu.com/').status_code
        #
        #     if code() == 200:
        #
        #         os.system('python D:\\拼多多站外工具箱\\requestTask.py')
        #
        #         break

    # except:
    #
    #     pass


if __name__ == '__main__':

    # checkPdd()


    while True:

        checkPdd()

        time.sleep(1)










# 223.104.175.137



